home *** CD-ROM | disk | FTP | other *** search
- diff -u -r --new-file last-version/docs/smb.conf.5 samba-1.9.14alpha19/docs/smb.conf.5
- --- last-version/docs/smb.conf.5 Thu Sep 14 09:57:46 1995
- +++ samba-1.9.14alpha19/docs/smb.conf.5 Sun Sep 17 10:28:23 1995
- @@ -779,8 +779,22 @@
-
- Typically the default service would be a public, read-only service.
-
- +Also not that s of 1.9.14 the apparent service name will be changed to
- +equal that of the requested service, this is very useful as it allows
- +you to use macros like %S to make a wildcard service.
- +
- +Note also that any _ characters in the name of the service used in the
- +default service will get mapped to a /. This allows for interesting
- +things.
- +
- +
- .B Example:
- default service = pub
- +
- + [pub]
- + path = /%S
- +
- +
- .SS deny hosts (S)
- A synonym for this parameter is 'hosts deny'.
-
- diff -u -r --new-file last-version/source/change-log samba-1.9.14alpha19/source/change-log
- --- last-version/source/change-log Sat Sep 16 12:12:30 1995
- +++ samba-1.9.14alpha19/source/change-log Wed Sep 20 00:33:10 1995
- @@ -1578,6 +1578,11 @@
- - changed error return code from cannor chdir() in make_connection
- - fixed realloc() bug in printing.c
- - fixed invalid username bug in sesssetupX
- + - released alpha18
- + - made default service change name to asked for service (idea
- + from Ian McEwan <ijm@doc.ic.ac.uk>)
- + - fixed "guest only" bug
- + - sambatar patches from Ricky
-
-
- ==========
- diff -u -r --new-file last-version/source/client.c samba-1.9.14alpha19/source/client.c
- --- last-version/source/client.c Fri Sep 15 21:05:13 1995
- +++ samba-1.9.14alpha19/source/client.c Sun Sep 17 09:55:11 1995
- @@ -3692,13 +3692,14 @@
- exit(1);
- }
-
- +/*
- if (count_chars(service,'\\') > 3)
- {
- usage(pname);
- printf("\n%s: Too many '\\' characters in service\n",service);
- exit(1);
- }
- -
- + */
-
- if (argc > 1 && (*argv[1] != '-'))
- {
- diff -u -r --new-file last-version/source/clitar.c samba-1.9.14alpha19/source/clitar.c
- --- last-version/source/clitar.c Fri Sep 15 20:24:05 1995
- +++ samba-1.9.14alpha19/source/clitar.c Wed Sep 20 00:30:15 1995
- @@ -2,7 +2,7 @@
- Unix SMB/Netbios implementation.
- Version 1.9.
- Tar Extensions
- - Copyright (C) Ricky Poulton 1995
- + Copyright (C) Ricky Poulten 1995
-
- This program is free software; you can redistribute it and/or modify
- it under the terms of the GNU General Public License as published by
- @@ -799,13 +799,13 @@
- * in that many fields, though
- */
-
- -/* check the checksum */
- + /* check the checksum */
- for (chk=0, i=sizeof(hb->dummy), jp=hb->dummy; --i>=0;) chk+=(0xFF & *jp++);
-
- if (chk == 0)
- return chk;
-
- -/* compensate for blanks in chksum header */
- + /* compensate for blanks in chksum header */
- for (i=sizeof(hb->dbuf.chksum), jp=hb->dbuf.chksum; --i>=0;)
- chk-=(0xFF & *jp++);
-
- @@ -814,7 +814,7 @@
- fchk=unoct(hb->dbuf.chksum, sizeof(hb->dbuf.chksum));
-
- DEBUG(5, ("checksum totals chk=%d fchk=%d chksum=%s\n",
- - chk, fchk, hb->dbuf.size));
- + chk, fchk, hb->dbuf.chksum));
-
- if (fchk != chk)
- {
- @@ -829,13 +829,17 @@
- strlen(hb->dbuf.name) + 1);
-
- /* can't handle links at present */
- - if (hb->dbuf.linkflag != '0')
- - {
- - DEBUG(0, ("this tar file appears to contain some kind of link\n"));
- + if (hb->dbuf.linkflag != '0') {
- + if (hb->dbuf.linkflag == 0) {
- + DEBUG(4, ("Warning: NULL link detected %s\n", finfo->name));
- + } else {
- + DEBUG(0, ("this tar file appears to contain some kind of link - ignoring\n"));
- return -2;
- }
- -
- - if (unoct(hb->dbuf.mode, sizeof(hb->dbuf.mode)) & S_IFDIR)
- + }
- +
- + if ((unoct(hb->dbuf.mode, sizeof(hb->dbuf.mode)) & S_IFDIR)
- + || (*(finfo->name+strlen(finfo->name)-1) == '\\'))
- {
- finfo->mode=aDIR;
- }
- @@ -896,7 +900,9 @@
- while (--ndgs)
- {
- if (isdigit(*p))
- - value = (value << 3) | (long) (*p++ - '0');
- + value = (value << 3) | (long) (*p - '0');
- +
- + p++;
- }
-
- return value;
- diff -u -r --new-file last-version/source/dir.c samba-1.9.14alpha19/source/dir.c
- --- last-version/source/dir.c Sat Sep 16 11:48:22 1995
- +++ samba-1.9.14alpha19/source/dir.c Sat Sep 16 18:59:37 1995
- @@ -622,7 +622,7 @@
- if (entry->next) entry->next->prev = entry;
- dir_cache = entry;
-
- - DEBUG(1,("Added dir cache entry %s %s -> %s\n",path,name,dname));
- + DEBUG(4,("Added dir cache entry %s %s -> %s\n",path,name,dname));
-
- if (dir_cache_size == DIRCACHESIZE) {
- for (entry=dir_cache; entry->next; entry=entry->next) ;
- @@ -648,7 +648,7 @@
- if (entry->snum == snum &&
- strcmp(path,entry->path) == 0 &&
- strcmp(name,entry->name) == 0) {
- - DEBUG(1,("Got dir cache hit on %s %s -> %s\n",path,name,entry->dname));
- + DEBUG(4,("Got dir cache hit on %s %s -> %s\n",path,name,entry->dname));
- return(entry->dname);
- }
- }
- diff -u -r --new-file last-version/source/includes.h samba-1.9.14alpha19/source/includes.h
- --- last-version/source/includes.h Fri Sep 15 20:28:21 1995
- +++ samba-1.9.14alpha19/source/includes.h Wed Sep 20 01:21:06 1995
- @@ -675,16 +675,26 @@
- #include <dirent.h>
- #include <string.h>
- #include <sys/vfs.h>
- -#include <netinet/in.h>
- -#include <errno.h>
- -#include <sys/wait.h>
- -#include <signal.h>
- #include <fcntl.h>
- #define DONT_REINSTALL_SIG
- #define USE_SIGBLOCK
- #define USE_WAITPID
- #define SIGNAL_CAST (_SigFunc_Ptr_t)
- #define NO_GETSPNAM
- +#define HAVE_MEMMOVE
- +extern char *mktemp(char *);
- +extern int fsync(int);
- +extern int seteuid(uid_t);
- +extern int setgroups(int, int *);
- +extern int initgroups(char *, int);
- +extern int statfs(char *, struct statfs *);
- +extern int setegid(gid_t);
- +extern int getopt(int, char *const *, const char *);
- +extern int chroot(char *);
- +extern int gettimeofday(struct timeval *, struct timezone *);
- +extern int gethostname(char *, int);
- +extern char *crypt(char *, char *);
- +extern char *getpass(char *);
- #endif
-
-
- diff -u -r --new-file last-version/source/ipc.c samba-1.9.14alpha19/source/ipc.c
- --- last-version/source/ipc.c Fri Sep 15 18:18:44 1995
- +++ samba-1.9.14alpha19/source/ipc.c Wed Sep 20 01:26:25 1995
- @@ -791,7 +791,7 @@
- if (uLevel > 1)
- {
- SSVAL(p,20,ACCESS_READ|ACCESS_WRITE|ACCESS_CREATE); /* permissions */
- - SSVAL(p,22,-1); /* max uses */
- + SSVALS(p,22,-1); /* max uses */
- SSVAL(p,24,1); /* current uses */
- SIVAL(p,26,PTR_DIFF(p2,baseaddr)); /* local pathname */
- len += CopyAndAdvance(&p2,lp_pathname(snum),&l2);
- @@ -953,7 +953,7 @@
- CVAL(p,9) = t->tm_min;
- CVAL(p,10) = t->tm_sec;
- CVAL(p,11) = 0; /* hundredths of seconds */
- - SSVAL(p,12,TimeDiff(0)/60); /* timezone in minutes from GMT */
- + SSVALS(p,12,TimeDiff(0)/60); /* timezone in minutes from GMT */
- SSVAL(p,14,10000); /* timer interval in 0.0001 of sec */
- CVAL(p,16) = t->tm_mday;
- CVAL(p,17) = t->tm_mon + 1;
- @@ -1477,15 +1477,15 @@
- p2 = skip_string(p2,1);
- SIVAL(p,52,0); /* last logon */
- SIVAL(p,56,0); /* last logoff */
- - SSVAL(p,60,-1); /* bad pw counts */
- - SSVAL(p,62,-1); /* num logons */
- + SSVALS(p,60,-1); /* bad pw counts */
- + SSVALS(p,62,-1); /* num logons */
- SIVAL(p,64,PTR_DIFF(p2,*rdata)); /* logon server */
- strcpy(p2,"\\\\GIGA");
- p2 = skip_string(p2,1);
- SSVAL(p,68,49); /* country code */
- SIVAL(p,70,0); /* workstations */
-
- - SIVAL(p,74,-1L); /* max storage */
- + SIVALS(p,74,-1); /* max storage */
- SSVAL(p,78,168); /* units per week */
- SIVAL(p,80,PTR_DIFF(p2,*rdata)); /* logon hours */
- memset(p2,-1,21);
- @@ -1494,7 +1494,7 @@
- }
- if (uLevel == 1 || uLevel == 2) {
- memset(p+22,' ',16); /* password */
- - SIVAL(p,38,-1); /* password age */
- + SIVALS(p,38,-1); /* password age */
- SSVAL(p,42,USER_PRIV_ADMIN); /* user privilege */
- SIVAL(p,44,PTR_DIFF(p2,*rdata)); /* home dir */
- strcpy(p2,"\\\\__SAMBA__\\HOMES");
- @@ -1515,14 +1515,14 @@
- SIVAL(p,76,0); /* workstations */
- SIVAL(p,80,0); /* last_logon */
- SIVAL(p,84,0); /* last_logoff */
- - SIVAL(p,88,-1); /* acct_expires */
- - SIVAL(p,92,-1); /* max_storage */
- + SIVALS(p,88,-1); /* acct_expires */
- + SIVALS(p,92,-1); /* max_storage */
- SSVAL(p,96,168); /* units_per_week */
- SIVAL(p,98,PTR_DIFF(p2,*rdata)); /* logon_hours */
- memset(p2,-1,21);
- p2 += 21;
- - SSVAL(p,102,-1); /* bad_pw_count */
- - SSVAL(p,104,-1); /* num_logons */
- + SSVALS(p,102,-1); /* bad_pw_count */
- + SSVALS(p,104,-1); /* num_logons */
- SIVAL(p,106,PTR_DIFF(p2,*rdata)); /* logon_server */
- strcpy(p2,"\\\\__SAMBA__");
- p2 = skip_string(p2,1);
- diff -u -r --new-file last-version/source/loadparm.c samba-1.9.14alpha19/source/loadparm.c
- --- last-version/source/loadparm.c Fri Sep 15 17:58:05 1995
- +++ samba-1.9.14alpha19/source/loadparm.c Sun Sep 17 09:53:17 1995
- @@ -837,6 +837,14 @@
- return(True);
- }
-
- +/***************************************************************************
- +add a new service, based on an old one
- +***************************************************************************/
- +int lp_add_service(char *pszService, int iDefaultService)
- +{
- + return(add_a_service(pSERVICE(iDefaultService),pszService));
- +}
- +
-
- /***************************************************************************
- add the IPC service
- diff -u -r --new-file last-version/source/loadparm.h samba-1.9.14alpha19/source/loadparm.h
- --- last-version/source/loadparm.h Fri Sep 15 17:58:30 1995
- +++ samba-1.9.14alpha19/source/loadparm.h Sun Sep 17 09:53:27 1995
- @@ -132,6 +132,7 @@
- extern int lp_servicenumber(char *pszServiceName);
- extern BOOL lp_add_home(char *pszHomename,
- int iDefaultService, char *pszHomedir);
- +extern int lp_add_service(char *service, int iDefaultService);
- extern BOOL lp_add_printer(char *pszPrintername, int iDefaultService);
- extern BOOL lp_readonly(int iService);
- extern int lp_create_mode(int iService);
- diff -u -r --new-file last-version/source/password.c samba-1.9.14alpha19/source/password.c
- --- last-version/source/password.c Sat Sep 16 12:02:07 1995
- +++ samba-1.9.14alpha19/source/password.c Tue Sep 19 14:48:12 1995
- @@ -92,7 +92,7 @@
- user_struct *get_valid_user_struct(int uid)
- {
- int vuid = valid_uid(uid);
- - if(vuid == -1)
- + if(vuid == -1 || validated_users[vuid].guest)
- return NULL;
- return &validated_users[vuid];
- }
- diff -u -r --new-file last-version/source/server.c samba-1.9.14alpha19/source/server.c
- --- last-version/source/server.c Sat Sep 16 11:35:14 1995
- +++ samba-1.9.14alpha19/source/server.c Tue Sep 19 14:46:56 1995
- @@ -888,8 +888,10 @@
- if (Connections[cnum].printer)
- flags |= O_CREAT;
-
- +/*
- if (flags == O_WRONLY)
- DEBUG(3,("Bug in client? Set O_WRONLY without O_CREAT\n"));
- +*/
-
- #if UTIME_WORKAROUND
- /* XXXX - is this OK?? */
- @@ -1638,7 +1640,8 @@
- }
- else
- {
- - uid = Connections[cnum].uid; /* Set this so done_become_user is set correctly */
- + uid = Connections[cnum].uid; /* Set this so done_become_user
- + is set correctly */
-
- if (initial_uid == 0)
- {
- @@ -1650,7 +1653,8 @@
- {
- /* groups stuff added by ih/wreu */
- if (Connections[cnum].ngroups > 0)
- - if (setgroups(Connections[cnum].ngroups,(GID_TYPE *)Connections[cnum].groups)<0)
- + if (setgroups(Connections[cnum].ngroups,
- + (GID_TYPE *)Connections[cnum].groups)<0)
- DEBUG(0,("setgroups call failed!\n"));
- }
- #endif
- @@ -1730,6 +1734,8 @@
- {
- int iService;
-
- + string_sub(service,"\\","/");
- +
- iService = lp_servicenumber(service);
-
- /* now handle the special case of a home directory */
- @@ -1778,8 +1784,13 @@
- if (iService < 0)
- {
- char *defservice = lp_defaultservice();
- - if (defservice && *defservice && !strequal(defservice,service))
- - return(find_service(defservice));
- + if (defservice && *defservice && !strequal(defservice,service)) {
- + iService = find_service(defservice);
- + if (iService >= 0) {
- + string_sub(service,"_","/");
- + iService = lp_add_service(service,iService);
- + }
- + }
- }
-
- if (iService >= 0)
- @@ -2329,8 +2340,9 @@
- }
- }
-
- - if (!lp_snum_ok(snum) || !check_access(snum))
- + if (!lp_snum_ok(snum) || !check_access(snum)) {
- return(-4);
- + }
-
- /* you can only connect to the IPC$ service as an ipc device */
- if (strequal(service,"IPC$"))
- @@ -2346,8 +2358,10 @@
-
- /* if the request is as a printer and you can't print then refuse */
- strupper(dev);
- - if (!lp_print_ok(snum) && (strncmp(dev,"LPT",3) == 0))
- + if (!lp_print_ok(snum) && (strncmp(dev,"LPT",3) == 0)) {
- + DEBUG(1,("Attempt to connect to non-printer as a printer\n"));
- return(-6);
- + }
-
- /* lowercase the user name */
- strlower(user);
- @@ -3181,7 +3195,7 @@
- {
- struct rlimit rlp;
- getrlimit(RLIMIT_CORE, &rlp);
- - rlp.rlim_cur = MAX(2*1024*1024,rlp.rlim_cur);
- + rlp.rlim_cur = MAX(4*1024*1024,rlp.rlim_cur);
- setrlimit(RLIMIT_CORE, &rlp);
- getrlimit(RLIMIT_CORE, &rlp);
- DEBUG(0,("Core limits now %d %d\n",rlp.rlim_cur,rlp.rlim_max));
- @@ -3202,6 +3216,7 @@
- int i;
- if (done_become_user != -1)
- unbecome_user();
- + DEBUG(1,("Closing connections\n"));
- for (i=0;i<MAX_CONNECTIONS;i++)
- if (Connections[i].open)
- close_cnum(i,-1);
- diff -u -r --new-file last-version/source/util.c samba-1.9.14alpha19/source/util.c
- --- last-version/source/util.c Fri Sep 15 21:06:29 1995
- +++ samba-1.9.14alpha19/source/util.c Wed Sep 20 01:23:04 1995
- @@ -590,7 +590,6 @@
- ****************************************************************************/
- void close_sockets(void )
- {
- - extern int Client;
- close(Client);
- Client = 0;
- }
- @@ -1347,7 +1346,6 @@
- ********************************************************************/
- char *GetWd(char *str)
- {
- - extern BOOL use_getwd_cache;
- pstring s;
- static BOOL getwd_cache_init = False;
- struct stat st, st2;
- diff -u -r --new-file last-version/source/version.h samba-1.9.14alpha19/source/version.h
- --- last-version/source/version.h Sat Sep 16 12:18:11 1995
- +++ samba-1.9.14alpha19/source/version.h Wed Sep 20 01:46:17 1995
- @@ -1 +1 @@
- -#define VERSION "1.9.14alpha18"
- +#define VERSION "1.9.14alpha19"
-